<template>
	<view class="coupon-wrapper">
		<view class="box" v-for="item in coupondata" :key="item.id">
			<view class="iii">
				<view class="zi1">￥{{item.price}}</view> <br>
				<view>{{item.title}}</view>
			</view>
			<view class="right">立即使用</view>
		</view>

		<view class="zi">没有更多数据了</view>
	</view>
</template>

<script>
	import {
		conList
	} from "../api/login.js"
	export default {
		data() {
			return {
				querymodel: {
					page: 1,
					limit: 10
				},
				coupondata: []
			}
		},
		onLoad() {
			this.getList()
		},
		methods: {
			async getList() {
				const res = await conList(this.querymodel)
				console.log(res, "11")
				this.coupondata = res.data.data.rows
			}
		}
	}
</script>

<style lang="scss">
	.coupon-wrapper {
		width: 100%;
		height: 100%;

		.zi {
			width: 100%;
			height: 60rpx;
			display: flex;
			align-items: center;
			justify-content: center;
			color: rgb(119, 119, 119);
			font-size: 28rpx;
		}

		.box {
			display: flex;
			justify-content: center;
			padding: 20rpx;
			margin-bottom: 20rpx;
		

			.iii {
				.zi1 {
					font-size: 37rpx !important;
				}

				width: 600rpx;
				height: 129rpx;
				padding: 20rpx;
				box-sizing: border-box;
				background-color: #d39e00;
				display: flex;
				flex-direction: column;
				align-items: flex-start;
				justify-content: center;
				color: white;
				font-size: 30rpx !important;
				border-right: 4px dashed white;
			}

			.right {
				width: 200rpx;
				height: 129rpx;
				display: flex;
				align-items: center;
				justify-content: center;
				background-color: #ffc107;
				font-size: 29rpx !important;
				color: white;
			}
		}
	}
</style>
